package com.itheima.d09_jdk8_localDate;

import java.time.LocalDate;
import java.util.ArrayList;

public class Test1 {
    public static void main(String[] args) {
        ArrayList<LocalDate> list = new ArrayList<>();
        LocalDate date = LocalDate.now();

        for (int i = 0; i < 30; i++){
            LocalDate date1 = date.plusDays(-i);
            list.add(date1);
        }
        //遍历打印集合
        for (LocalDate localDate : list) {
            System.out.println(localDate);
        }

    }
}
